use strict;
use warnings;
use Data::Dumper;
use XML::Simple;

my $xmlFile = "vendor.xml";
my $output;

my $volte = 'carrier_volte';
my $vowifi = 'carrier_vowifi';
my $vilte = 'carrier_volte';
my $xmlKey = 'carrier_config';
my $opKey = 'operator';

my $isCompact = 'false';

my $xmlRef = XMLin($xmlFile, ForceArray=>1);
my @config = @{$xmlRef->{$xmlKey}};


foreach my $ref (@config) {
    if ($ref->{$opKey}) {
        my @subConfig = @{$ref->{'boolean'}};
        foreach my $subRef (@subConfig) {
             
        }
      #for compacted type
    } else {
      #for old type  
    }
}

print Dumper($xmlRef);